package com.king.springcloud.controller;

import com.king.springcloud.domain.CommonResult;
import com.king.springcloud.service.AccountService;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.math.BigDecimal;

/**
 * @author king
 * @date 2020/10/21 0:12
 */
@RestController
public class AccountController {

    @Resource
    private AccountService accountService;


    @RequestMapping("/account/decrease")
    CommonResult decrease(Long userId, Integer money){
        return accountService.decrease(userId, money);
    }
}
